Skip to content

Conversation

@devanshjainms
Copy link
Contributor

This pull request introduces several updates across multiple files, focusing on improving functionality, enhancing configurability, and addressing issues in high availability (HA) setups for SAP HANA on Azure. Key changes include updates to filesystem handling, resource configurations, and test case setups.

Filesystem and Mount Handling:

  • Updated the _find_filesystem method in src/modules/filesystem_freeze.py to return both the filesystem and mount point, improving clarity and enabling more precise operations.
  • Modified the FREEZE_FILESYSTEM command in src/module_utils/commands.py to accept a mount point as a parameter, aligning with the updated _find_filesystem method.

Resource Configuration Enhancements:

  • Updated resource categories in src/modules/get_pcmk_properties_db.py to include specific types like sbd_stonith and fence_agent for better granularity.
  • Adjusted RESOURCE_DEFAULTS in constants.yaml to refine timeout values and add specific configurations for sbd_stonith. [1] [2]

Test Case and Validation Improvements:

  • Added logic to dynamically determine the HANA resource ID during test execution in resource-migration.yml, improving flexibility across different setups.
  • Introduced default values and commands for HANA DB HA test cases in input-api.yaml, centralizing configuration and reducing duplication. [1] [2]

Security and Data Handling:

  • Updated _parse_nvpair_elements in both get_pcmk_properties_db.py and get_pcmk_properties_scs.py to skip sensitive parameters like passwd and password, enhancing security. [1] [2]

Documentation and Miscellaneous:

  • Updated the Azure Load Balancer IAM configuration steps in HIGH_AVAILABILITY.md to reference the correct documentation link.
  • Removed the installation of the azure-mgmt-network package in azure-lb.yml, likely due to redundancy or a shift in dependency management.

@devanshjainms devanshjainms requested a review from a team as a code owner April 22, 2025 15:25
@devanshjainms devanshjainms requested review from KimForss, Copilot, hdamecharla and mkdeegan and removed request for mkdeegan April 22, 2025 15:25
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances code clarity and updates resource configurations for high availability systems in SAP HANA deployments on Azure by improving filesystem handling, refining resource properties, and updating test case setups. Key changes include updates to filesystem freeze methods, enhanced resource configuration defaults, and modifications to test commands and validation logic.

Reviewed Changes

Copilot reviewed 19 out of 20 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tests/roles/ha_db_hana/resource_migration_test.py Updated command templating and added a new resource ID retrieval command for HANA.
tests/roles/ha_db_hana/block_network_test.py Replaced ping with nc for network blocking tests and updated in-code comments accordingly.
tests/modules/get_pcmk_properties_db_test.py Added sensitive parameters for testing scenario, ensuring they are skipped during processing.
tests/modules/filesystem_freeze_test.py Adjusted mount point expectations in filesystem freeze tests.
src/vars/input-api.yaml Updated default values and command templating for HANA DB HA test cases.
src/roles/misc/tasks/test-case-setup.yml & rescue.yml Minor updates in variable setups for improved clarity in test case configuration.
src/roles/ha_db_hana/tasks/resource-migration.yml Introduced a new block to retrieve HANA resource id with fallback handling.
src/roles/ha_db_hana/tasks/files/constants.yaml Updated resource default timeout and delay values, and renamed resource key for clarity.
src/roles/ha_db_hana/tasks/block-network.yml Modified network connectivity check to use nc instead of ping.
src/module_utils/commands.py Modified the FREEZE_FILESYSTEM lambda to accept a mount point parameter.
docs/HIGH_AVAILABILITY.md Revised documentation instructions with updated documentation links.
src/modules/get_pcmk_properties_scs.py, src/modules/get_pcmk_properties_db.py Updated parsing logic to skip sensitive data in NV pair elements and refined resource configuration retrieval.
src/modules/filesystem_freeze.py Adjusted _find_filesystem to return a tuple and updated corresponding command invocations.
src/modules/check_indexserver.py Updated expected properties structure for SUSE to a list format for consistency.
Files not reviewed (1)
  • tests/roles/mock_data/cibadmin.txt: Language not supported
Comments suppressed due to low confidence (1)

src/roles/ha_db_hana/tasks/files/constants.yaml:62

  • The value for pcmk_delay_max was changed from '30s' to '15' without a unit. Verify that this numeric value is processed as intended downstream and that the absence of a unit does not cause issues.
        pcmk_delay_max:                 "15"

@devanshjainms devanshjainms added bug Something isn't working dependencies Pull requests that update a dependency file python Pull requests that update python code labels Apr 22, 2025
Copy link

@KimForss KimForss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two questions, see comments

@KimForss KimForss self-requested a review April 22, 2025 19:29
KimForss
KimForss previously approved these changes Apr 22, 2025
Copy link
Contributor

@dennispadia dennispadia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

Copy link
Member

@hdamecharla hdamecharla left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

Copy link
Contributor

@dennispadia dennispadia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@devanshjainms devanshjainms merged commit 4198651 into Azure:main Apr 22, 2025
11 checks passed
@devanshjainms devanshjainms deleted the hotfix-april25-2 branch April 22, 2025 22:21
devanshjainms added a commit to devanshjainms/sap-automation-qa that referenced this pull request Apr 22, 2025
devanshjainms added a commit to devanshjainms/sap-automation-qa that referenced this pull request Apr 22, 2025
devanshjainms added a commit that referenced this pull request Apr 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working dependencies Pull requests that update a dependency file python Pull requests that update python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants